Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat #71 GET /submissions/{submissionId} を実装する #76

Merged
merged 4 commits into from
Jan 10, 2025

Conversation

kavos113
Copy link
Collaborator

関連Issue

概要

GET /submissions/{submissionId} を実装

変更内容

  • get_submissionとして実装
  • データベースへのアクセス: get_submission_by_id, get_testcases_by_submission_idとして実装
  • get_normal_problems_by_idの実装

補足

問題が公開でないかつ作問者でないときに404エラーを返す

@kavos113 kavos113 requested a review from PonponJuice January 10, 2025 08:21
src/handler/submissions.rs Show resolved Hide resolved
src/handler/submissions.rs Show resolved Hide resolved
.get_display_id_by_session_id(session_id)
.await
.map_err(|_| StatusCode::INTERNAL_SERVER_ERROR)?
.ok_or(StatusCode::UNAUTHORIZED)?;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ログインしてなくても見れるようにしていい

Copy link
Collaborator

@PonponJuice PonponJuice left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kavos113 kavos113 merged commit 02e44e8 into develop Jan 10, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GET /submissions/{submissionId} を実装する
2 participants